package com.chengzhi.web;

import com.chengzhi.web.feign.HelloFeign;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 *
 * @description feign 集成了ribbon和eureka
 * @param
 * @author RCZ
 * @create 2018-01-10 21:29
 */
@RestController
public class HelloController {
        @Resource
        private HelloFeign helloFeign;
        @RequestMapping("query")
        public String query() {
            System.out.println("feign 调用");
            return helloFeign.helloWorld();
        }
}
